var layObj = {
	'open': function(url, width, height, title, callback) {
		callback = callback ? callback : false;
		layer.open({
			type: 2,
			title: title,
			shadeClose: true,
			shade: 0.1,
			area: [width + 'px', height + 'px'],
			fix: false,
			content: url,
			success: function(layero, index) {
				if(callback) {
					callback(layero, index);
				}
			}
		});
	},
	'layerPost': function(url, width, height, title, postData, contentUrl, callback) {
		//Ajax获取
		$.post(url, postData, function() {
			layer.open({
				type: 2,
				title: title,
				shadeClose: true,
				shade: 0.8,
				area: [width + 'px', height + 'px'],
				fix: false,
				content: contentUrl,
				success: function(layero, index) {
					if(callback) {
						callback(layero, index);
					}
				}
			});
		});
	},
	'notice': function(url, width, height, title, callback) {
		layer.open({
			type: 2,
			title: false,
			shadeClose: true,
			shade: 0.8,
			area: [width + 'px', height + 'px'],
			content: url,
			skin: 'notitleClass',
			success: function(layero, index) {
				if(callback) {
					callback(layero, index);
				}
			}
		});
	},
	'content': function(width, height, title, contentHtml, skin, callback) {
		skin = skin ? skin : '';
		layer.open({
			type: 1,
			title: title,
			skin: skin,
			area: [width + 'px', height + 'px'], //宽高
			content: contentHtml,
			success: function(layero,index) {
				if(callback) {
					callback(layero,index);
				}
			}
		});
	},
	msg: function(msg) {
		layer.msg(msg);
	},
	confirm: function(msg, title,width,height,skin, yesFun, noFun) {
		//询问框
		layer.confirm(msg, {
			title: title,
			area: [width + 'px', height + 'px'],
			skin:skin,
			btn: [yesFun.msg, noFun.msg] //按钮
		}, function(index) {
			yesFun.callback(index);
//			layer.close(index);
		}, function(index) {
			noFun.callback(index);
//			layer.close(index);
		});
	}
}